<html>
	<head>
			<style type="text/css">
					 .translucent
					{
					    filter:alpha(opacity=60);
					    -moz-opacity:0.6;
					    opacity:0.6;
					}
					
				</style>
				
	</head>
	<body>
		<a href="javascript:OpenDIV()" id="aClick" >Click Here</a>
		<input type="text" id="txtDate" onfocus="this.select();lcs(this)" onclick="event.cancelBubble=true;this.select();lcs(this)" />
		
	<div id="blockUI" class="translucent" style='border:0px solid Blue;display: none; background-color: Black;width: 800px; height: 700px;position: absolute;  z-index: 10000;' onclick="return false" onmousedown="return false" onmousemove="return false" onmouseup="return false" ondblclick="return false"></div>

<div id="divPostEntry" style="display:none;background-color:Black;width:600px;height:500px;position:absolute;border:2px solid #FFFFCC">
		<table style="width:100%;background-color:#88AAD6;font-family:Arial,Verdana;border:1px solid black">
				<tr>
						<td style="width:50%" align="left">
								Post entry
						</td>
						<td style="width:50%" align="right">
								<a href="javascript:CloseWindow('divPostEntry')" style="color:Black;text-decoration:none">X</a>
						</td>
				</tr>
		</table>
		
		<iframe id="ifr" style="border:0px;width:550px;height:470px" src="InsertForm.html">
		</iframe>
		

</div>	
				
			<script type="text/javascript">
				
			function CloseWindow(id)
			{
					document.getElementById(id).style.display="none"
					BlurBackground()
					//RemoveDummy()
			}
			function OpenDIV()
			{
					var obj=document.getElementById("divPostEntry")
					
					var pos=ObjectCoOrdinates("aClick")
			    BlurBackground()
			    //DrawDummy("divPostEntry")
			    
			    
			    obj.style.top=parseInt(pos.y+40)+"px"
			    obj.style.left=parseInt(pos.x+100)+"px"
			    obj.style.zIndex=10000
			    obj.style.display=""
			}
			
			function BlurBackground()
			{
			    
			    
			    var objBlockUI=document.getElementById("blockUI")
			    var isVisible=objBlockUI.style.display
			    var objTable=document.getElementById("tblBlockUI")
			    var pos=ObjectCoOrdinates("tblBlockUI")
			    
			    
			    objBlockUI.style.position="absolute"
			    objBlockUI.style.top="0px"
			    objBlockUI.style.left="0px"

			    var dimensions=GetDimensions()
			    objBlockUI.style.zIndex=100
			    objBlockUI.style.height=dimensions.y+"px"
			    objBlockUI.style.width=dimensions.x+"px"
			    //objBlockUI.style.height="825px"
			    
			   // objBlockUI.style.width="780px"
			    
			    if(isVisible=="none")
			    {
			       
			        objBlockUI.style.display=""
			    }
			    else
			    {
			         objBlockUI.style.display="none"
			    }
			   
			}
			function GetDimensions()
			{
			    var pos=new Position()
			    
			    if (typeof event!="undefined")
			    {
			        
			        pos.x=document.documentElement.scrollWidth
			        pos.y=document.documentElement.offsetHeight
			    }
			    else
			    {
			        
			        pos.x=document.documentElement.scrollWidth
			        //pos.y=document.documentElement.scrollHeight
			        pos.y=window.outerHeight
			    }
			    return pos
			}
			
			
			
			function Position()
			{
			this.x=""
			this.y=""
			}
			
			
			function DrawDummy(id)
			
			{
			    var obj=document.getElementById(id)
			    var objParent
			    var objDirt=document.createElement("div")
			    objDirt.id="divDummy"
			    objParent=obj.parentElement || obj.parentNode
			    objParent.appendChild(objDirt)
			    objParent.removeChild(obj)
			    
			    document.body.appendChild(obj)
			}
			function RemoveDummy(id)
			{
			    var objDirt=document.getElementById("divDummy")
			    var objParent=objDirt.parentElement || objDirt.parentNode
			    
			    objParent.removeChild(objDirt)
			    objParent.appendChild(document.getElementById(id))
			}
			function ObjectCoOrdinates(strObjectName)
{
        var el = document.getElementById(strObjectName)
      
        var totalOffsetTop = 0;
        var totalOffsetLeft=0
        var pos=new Position()
        if (el==null)
        {
         pos.x=-1
         pos.y=-1
         return pos   
        }  
        while (el != null) 
        {
            totalOffsetTop += el.offsetTop;
            totalOffsetLeft+= el.offsetLeft;
            el = el.offsetParent;
        }
        pos.y=totalOffsetTop
        pos.x=totalOffsetLeft
        return pos
}

				</script>
	</body>
</html>